﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data.EntityClient;
using System.Data.Objects;
using JChatCore.City;
using JChatCore.CounTry;
using JChatCore.Log;
using JChatCore.Topic;
using JChatCore.User;
namespace JChatData.Helper
{
   public class ChatModel:ObjectContext
    {
        /// <summary>
        /// Entity model
        /// Code by Linh Pham
        /// </summary>
        /// <param name="con"></param>
        public ChatModel(EntityConnection con)
            : base(con)
        {
            DefaultContainerName = "ChatModel";
        }

        //Table User
        public IObjectSet<User> JChat_User
        {
            get { return base.CreateObjectSet<User>(); }
        }

        //Table Topic
        public IObjectSet<Topic> JChat_Topic
        {
            get { return base.CreateObjectSet<Topic>(); }
        }

        //Table City
        public IObjectSet<City> JChat_City
        {
            get { return base.CreateObjectSet<City>(); }
        }

        //Table Country
        public IObjectSet<CounTry> JChat_CounTry
        {
            get { return base.CreateObjectSet<CounTry>(); }
        }

        //Table Log
        public IObjectSet<Log> JChat_Log
        {
            get { return base.CreateObjectSet<Log>(); }
        }
    }
}
